<%@ page language="java" contentType="text/html; charset=utf-8"
    pageEncoding="utf-8"%>
<%@page import="com.tmpt.dto.ConstantDto"%>
<%@page import="com.tmpt.dto.CustomerDto"%>
<%@include file="../base.jsp"%>

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>商城用户-密码重置</title>
<link rel="stylesheet" type="text/css" href="${path}/js/jquery/easyui/themes/default/linkbutton.css">
<link rel="stylesheet" type="text/css" href="${path}/js/jquery/easyui/themes/default/validatebox.css">
<link rel="stylesheet" type="text/css" href="${path}/js/jquery/easyui/themes/icon.css">
<link href="${path}/front/product/css/common.css" rel="stylesheet" type="text/css" />
<link href="css/center.css" rel="stylesheet" type="text/css" />

<script src="${path}/js/jquery/easyui/jquery-1.8.0.min.js"></script>
<script src="${path}/js/jquery/easyui/jquery.easyui.min.js"></script>
<script src="${path}/front/product/js/common.js"></script>
<!-- rsa -->
<script type="text/javascript" src="${path}/js/rsa_js/RSA.js"></script>
<script type="text/javascript" src="${path}/js/rsa_js/BigInt.js"></script>
<script type="text/javascript" src="${path}/js/rsa_js/Barrett.js"></script>
<script type="text/javascript" src="${path}/js/rsa_js/myrsa.js"></script>
<script type="text/javascript">

function onEnterPressDown(){
	if(event.keyCode=='13'){
		submit1();
	}
} 
function submit1(){
  if(!$('#form1').form('validate')){
	  alert('数据不完整');
	  return ;
  }
  
  if($('#passwordVerify').val()!=$('#rsaPasswordId').val()){
	    alert('两次输入新密码不相同'); 
	    return;
  }
  $('#passwordVerify').val('');

 // rsaPwd('PasswordId');
  rsaPwd('rsaPasswordId');
  document.form1.submit();
}
</script>
</head>
<body>

<div id="main">
	<div id="mainLeft" >
	</div>
	<div id="mainRight">
	    <br/>
	    <div align="center" style="color: red;">
	    	<s:property value="#attr.result"/>
	    </div>
	    <div style="margin: 20px auto;">
		<div class="title" align="center">密码重置</div>
			<s:form name="form1" id="form1" action="customer_resetPassword.action" namespace="/admin123/user" method="post" theme="simple">
			<table style="line-height: 40px;" cellpadding="0" cellspacing="0" width="450" align="center">
				<tbody>
				<tr>
					<td align="right">
						<font color="red" title="必填项" style="cursor: pointer;">*</font>新密码：
					</td>
					<td align="left">
						<input type="password" name="newPassword" id="rsaPasswordId" class="easyui-validatebox" data-options="required:true,missingMessage:'注:密码长度范围为6-40位字符,且不能为纯数字或纯字母'" maxlength="40">
						<input type="button" value="密码安全控件" onclick="showkeyboard('form1.newPassword')">
					</td>
				</tr>
				<tr>
					<td align="right">
						<font color="red" title="必填项" style="cursor: pointer;">*</font>确认密码：
					</td>
					<td align="left">
						<input type="password" name="passwordVerify" id="passwordVerify" class="easyui-validatebox" data-options="required:true" maxlength="40">
						<input type="button" value="密码安全控件" onclick="showkeyboard('form1.passwordVerify')">
					</td>
				</tr>
		      	<tr>
		      		<td colspan="2">
		      			<div id="keyboardContainer" style="position: absolute;z-index:18000;"/>
		      		</td>
		      	</tr>
		      	<tr>
		      		<td colspan="2" style="text-align: left; padding-left: 40px;">
		      			<font color="red"> 注：密码长度范围为6-40位字符,且不能为纯数字或纯字母</font>
		      		</td>
		      	</tr>
				</tbody>
				<tfoot>
				<tr>
					<td colspan="2" align="center">
						<a href="javascript:void(0);" 
							class="easyui-linkbutton" 
							data-options="iconCls:'icon-pencil'"
							onclick="javascript:submit1();">
							修改密码</a>
					</td>
				</tr>
				</tfoot>
			</table>
			<input type="hidden" name="loginName" id="loginName" value ="${param.loginName}">
			</s:form>
		</div>
	</div>
	<div style="clear: both;"></div>
</div>

<div style="height:30px;"></div>

</body>
<script type="text/javascript" src="${path}/js/keyboard.js"></script>
</html>

